package com.crazy.model.major.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDateTime;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;

/**
 * <p>
 * 角色表
 * </p>
 *
 * @author ${author}
 * @since 2020-12-24
 */
@TableName("T_USER_ROLE")
public class TUserRole extends Model<TUserRole> {

    /**
    * 所有字段名
    */
    public static class Columns {
        /**
        * 
        */
        public static final String id = "ID";
        /**
        * 角色名称
        */
        public static final String roleName = "ROLE_NAME";
        /**
        * 
        */
        public static final String createTime = "CREATE_TIME";
        /**
        * 
        */
        public static final String updateTime = "UPDATE_TIME";
        /**
        * 描述
        */
        public static final String descript = "DESCRIPT";
        /**
        * 有效（0：无效，1：有效）
        */
        public static final String valid = "VALID";
        /**
        * 角色权限
        */
        public static final String requireRole = "REQUIRE_ROLE";
    }

    @TableId(value = "ID", type = IdType.AUTO)
    private Long id;

    /**
     * 角色名称
     */
    @TableField("ROLE_NAME")
    private String roleName;

    @TableField("CREATE_TIME")
    private LocalDateTime createTime;

    @TableField("UPDATE_TIME")
    private LocalDateTime updateTime;

    /**
     * 描述
     */
    @TableField("DESCRIPT")
    private String descript;

    /**
     * 有效（0：无效，1：有效）
     */
    @TableField("VALID")
    private Integer valid;

    /**
     * 角色权限
     */
    @TableField("REQUIRE_ROLE")
    private String requireRole;


    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getRoleName() {
        return roleName;
    }

    public void setRoleName(String roleName) {
        this.roleName = roleName;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    public LocalDateTime getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(LocalDateTime updateTime) {
        this.updateTime = updateTime;
    }

    public String getDescript() {
        return descript;
    }

    public void setDescript(String descript) {
        this.descript = descript;
    }

    public Integer getValid() {
        return valid;
    }

    public void setValid(Integer valid) {
        this.valid = valid;
    }

    public String getRequireRole() {
        return requireRole;
    }

    public void setRequireRole(String requireRole) {
        this.requireRole = requireRole;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "TUserRole{" +
        "id=" + id +
        ", roleName=" + roleName +
        ", createTime=" + createTime +
        ", updateTime=" + updateTime +
        ", descript=" + descript +
        ", valid=" + valid +
        ", requireRole=" + requireRole +
        "}";
    }
}
